﻿using SqlSugar;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ComprehensiveSystem.Model.Entities
{
    [SugarTable("Patient", TableDescription = "病人信息表")]
    [DatabaseType("Base_Sap_Patient_ZY_NEW")]
    public class PatientEntity : BaseEntity
    {
        /// <summary>
        /// 
        /// </summary>
        //public string Id { set; get; }

        /// <summary>
        /// 
        /// </summary>
        public string CaseNumber { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public string RealName { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public int? Age { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public int? Sex { set; get; }

        /// <summary>
        /// 身高
        /// </summary>
        public double? Height { set; get; }
        /// <summary>
        /// 体重
        /// </summary>
        public double? Weight { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public double? BMI { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public string Address { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public string Telephone { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public string HosPitalId { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public int? SDDPAPID { set; get; }
        /// <summary>
        /// 
        /// </summary>
        public string Hospital_Now { set; get; }
        /// <summary>
        /// 
        /// </summary>
        //   public int PNumber { set; get; }
        /// <summary>
        /// 手术次数
        /// </summary>
        public int? SurgeryNumber { set; get; }
        /// <summary>
        /// 住院费用（元）
        /// </summary>
        public double? InHospitalCost { set; get; }
        /// <summary>
        /// 严重并发症（0 无/1 有）
        /// </summary>
        public int? SeriousComplication { set; get; }
        /// <summary>
        /// 病人来源标识（0 SAP/1 路径）
        /// </summary>
        public int? IdentityMark { set; get; }

        /// <summary>
        /// 住院天数
        /// </summary>
        public double? LiveDay { set; get; }

        /// <summary>
        /// ICU天数
        /// </summary>
        public double? ICUDay { set; get; }

        /// <summary>
        /// 住院天数是否有手动修改（0 否/1 是）
        /// </summary>
        public int? LiveDay_IsUpdate { set; get; } = 0;

        /// <summary>
        /// ICU天数是否有手动修改（0 否/1 是）
        /// </summary>
        public int? ICUDay_IsUpdate { set; get; } = 0;

        /// <summary>
        /// 路径代码
        /// </summary>
        public string PathCode { set; get; }

        /// <summary>
        /// 校正后的路径代码
        /// </summary>
        public string CheckPathCode { set; get; }

        /// <summary>
        /// 已传输路径代码标识（1 已传输）
        /// </summary>
        public int? PathCodeMark { set; get; } = 0;

        /// <summary>
        /// 路径开始到结束时间
        /// </summary>
        public string StartToEndJson { set; get; }

        [SugarColumn(IsIgnore = true)]
        public string BriefSummary { set; get; }
    }
}
